<template>
  <div>
    <el-table :data="data" border stripe style="width: 100%">
      <el-table-column prop="batch_no" label="批次号" width="220" />
      <el-table-column prop="tx_id" label="交易哈希" width="220" />
      <el-table-column prop="contract_result" label="结果摘要" />
      <el-table-column prop="tx_message" label="消息" />
      <el-table-column prop="create_time" label="上链时间" width="160" />
    </el-table>
    <el-pagination
      layout="prev, pager, next"
      :page-size="10"
      :total="total"
      :current-page="page"
      @current-change="page => $emit('pageChange', page)"
      class="pagination"
    />
  </div>
</template>

<script setup>
const props = defineProps(['data', 'total', 'page']);
</script>